package com.chefu.admin.pojo;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 
 * </p>
 *
 * @author goodgoodstudy
 * @since 2021-03-31
 */
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("tb_service_provider")
@ApiModel(value="ServiceProvider对象", description="")
public class ServiceProvider implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "服务商id")
    @TableId(value = "sp_id", type = IdType.ID_WORKER)
    private Long spId;

    @ApiModelProperty(value = "省市区id")
    @NotNull(message = "区域不能为空")
    private Long areaId;

    @ApiModelProperty(value = "服务商全称")
    @NotNull(message = "服务商全称不能为空")
    private String fullName;

    @ApiModelProperty(value = "服务商简称")
    @NotNull(message = "服务商简称不能为空")
    private String shortName;

    @ApiModelProperty(value = "联系人")
    @NotNull(message = "联系人不能为空")
    private String contact;

    @ApiModelProperty(value = "联系人电话")
    @Pattern(message = "联系人电话不合法",regexp = "^((13[0-9])|(14[5-8])|(15([0-3]|[5-9]))|(16[6])|(17[0|4|6|7|8])|(18[0-9])|(19[8-9]))\\d{8}$")
    private String phone;

    @ApiModelProperty(value = "详细地址")
    @NotNull(message = "详细地址不能为空")
    private String address;

    @ApiModelProperty(value = "是否连锁（1：是 0：否）")
    private Boolean tChain;

    @ApiModelProperty(value = "是否审核通过（0：未通过 1：通过 2：拒绝）")
    private Integer tCheck;

    @ApiModelProperty(value = "用户类别（1：服务商 2：配件商）")
    private Integer puType;

    @ApiModelProperty(value = "相关证件照，多个图片逗号分割")
    private String images;

    @ApiModelProperty(value = "经度")
    private Double longitude;

    @ApiModelProperty(value = "纬度")
    private Double latitude;

    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    @ApiModelProperty(value = "修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

    @ApiModelProperty(value = "省")
    private String tProvince;

    @ApiModelProperty(value = "市")
    private String tCity;

    @ApiModelProperty(value = "区")
    private String tArea;

    @ApiModelProperty(value = "厂商类型（1：服务商 2：配件商）")
    private Integer tType;

    @ApiModelProperty(value = "状态（锁定0正常1）")
    private Integer status;

    @ApiModelProperty(value = "来源")
    private String tOrigin;

    @ApiModelProperty(value = "类型标签")
    private String tag;

    public Long getSpId() {
        return spId;
    }

    public void setSpId(Long spId) {
        this.spId = spId;
    }

    public Long getAreaId() {
        return areaId;
    }

    public void setAreaId(Long areaId) {
        this.areaId = areaId;
    }

    public String getFullName() {
        return fullName;
    }

    public void setFullName(String fullName) {
        this.fullName = fullName;
    }

    public String getShortName() {
        return shortName;
    }

    public void setShortName(String shortName) {
        this.shortName = shortName;
    }

    public String getContact() {
        return contact;
    }

    public void setContact(String contact) {
        this.contact = contact;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public Boolean gettChain() {
        return tChain;
    }

    public void settChain(Boolean tChain) {
        this.tChain = tChain;
    }

    public Integer gettCheck() {
        return tCheck;
    }

    public void settCheck(Integer tCheck) {
        this.tCheck = tCheck;
    }

    public Integer getPuType() {
        return puType;
    }

    public void setPuType(Integer puType) {
        this.puType = puType;
    }

    public String getImages() {
        return images;
    }

    public void setImages(String images) {
        this.images = images;
    }

    public Double getLongitude() {
        return longitude;
    }

    public void setLongitude(Double longitude) {
        this.longitude = longitude;
    }

    public Double getLatitude() {
        return latitude;
    }

    public void setLatitude(Double latitude) {
        this.latitude = latitude;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public String gettProvince() {
        return tProvince;
    }

    public void settProvince(String tProvince) {
        this.tProvince = tProvince;
    }

    public String gettCity() {
        return tCity;
    }

    public void settCity(String tCity) {
        this.tCity = tCity;
    }

    public String gettArea() {
        return tArea;
    }

    public void settArea(String tArea) {
        this.tArea = tArea;
    }

    public String gettType() {
        return tType;
    }

    public void settType(String tType) {
        this.tType = tType;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String gettOrigin() {
        return tOrigin;
    }

    public void settOrigin(String tOrigin) {
        this.tOrigin = tOrigin;
    }

    public String getTag() {
        return tag;
    }

    public void setTag(String tag) {
        this.tag = tag;
    }
}
